<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.6"/>
<title>libnetconf: Transaction API</title>
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../jquery.js"></script>
<script type="text/javascript" src="../../dynsections.js"></script>
<link href="../../navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../resize.js"></script>
<script type="text/javascript" src="../../navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="../../doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="../../libnetconf-logo.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">libnetconf
   &#160;<span id="projectnumber">0.10.0-146_trunk</span>
   </div>
   <div id="projectbrief">NETCONF Library</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.6 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="../../index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="../../pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="../../modules.html"><span>Modules</span></a></li>
      <li><a href="../../annotated.html"><span>Data&#160;Structures</span></a></li>
      <li><a href="../../files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="../../search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="../../search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('d8/d55/group__transapi.html','../../');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Data Structures</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Macros</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&#160;</span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(10)"><span class="SelectionMark">&#160;</span>Pages</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#nested-classes">Data Structures</a> &#124;
<a href="#enum-members">Enumerations</a> &#124;
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">Transaction API</div>  </div>
</div><!--header-->
<div class="contents">

<p>libnetconf's implementation of transaction-based partial device reconfiguration.  
<a href="#details">More...</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
Data Structures</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d0/dd1/structclbk.html">clbk</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Structure describing callback - path + function.  <a href="../../d0/dd1/structclbk.html#details">More...</a><br/></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d9/dc0/structtransapi.html">transapi</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Structure to describe transAPI module and connect it statically with libnetconf using <a class="el" href="../../d8/d55/group__transapi.html#gaaf4e4daa7fa8be965ded41eb006a6713" title="Create new datastore structure with transaction API support. ">ncds_new_transapi_static()</a>.  <a href="../../d9/dc0/structtransapi.html#details">More...</a><br/></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d6/dcb/structtransapi__data__callbacks.html">transapi_data_callbacks</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Same as <a class="el" href="../../d6/dcb/structtransapi__data__callbacks.html" title="Same as transapi_data_callbacks. Using libxml2 structures for callbacks parameters. ">transapi_data_callbacks</a>. Using libxml2 structures for callbacks parameters.  <a href="../../d6/dcb/structtransapi__data__callbacks.html#details">More...</a><br/></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/df8/structtransapi__file__callbacks.html">transapi_file_callbacks</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Functions to call if the specified file is modified.  <a href="../../de/df8/structtransapi__file__callbacks.html#details">More...</a><br/></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d0/df8/structtransapi__rpc__callbacks.html">transapi_rpc_callbacks</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Same as <a class="el" href="../../d0/df8/structtransapi__rpc__callbacks.html" title="Same as transapi_rpc_callbacks. Using libxml2 structures for callbacks parameters. ">transapi_rpc_callbacks</a>. Using libxml2 structures for callbacks parameters.  <a href="../../d0/df8/structtransapi__rpc__callbacks.html#details">More...</a><br/></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="enum-members"></a>
Enumerations</h2></td></tr>
<tr class="memitem:ga10d59d84527f735d2781dbbb629a4488"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d8/d55/group__transapi.html#ga10d59d84527f735d2781dbbb629a4488">XMLDIFF_OP</a> { <br/>
&#160;&#160;<a class="el" href="../../d8/d55/group__transapi.html#gga10d59d84527f735d2781dbbb629a4488af2c3cac34cb7553ac93e8f3ad8acee3c">XMLDIFF_ERR</a> = -1, 
<a class="el" href="../../d8/d55/group__transapi.html#gga10d59d84527f735d2781dbbb629a4488a45a3557c464a0d85a333b68634df5561">XMLDIFF_NONE</a> = 0, 
<a class="el" href="../../d8/d55/group__transapi.html#gga10d59d84527f735d2781dbbb629a4488adc0f4fc8354a1e293db5efd4f8e6f0b1">XMLDIFF_ADD</a> = 1, 
<a class="el" href="../../d8/d55/group__transapi.html#gga10d59d84527f735d2781dbbb629a4488a149cdeec9d87bdbb700861f773759129">XMLDIFF_REM</a> = 2, 
<br/>
&#160;&#160;<a class="el" href="../../d8/d55/group__transapi.html#gga10d59d84527f735d2781dbbb629a4488a27c20d1fff6c4a35673bea8c6bbe23c4">XMLDIFF_MOD</a> = 4, 
<a class="el" href="../../d8/d55/group__transapi.html#gga10d59d84527f735d2781dbbb629a4488a4038204cbce3cfa24153b304b95e99a6">XMLDIFF_CHAIN</a> = 8, 
<a class="el" href="../../d8/d55/group__transapi.html#gga10d59d84527f735d2781dbbb629a4488afed6f3e2b762ffe2cad87676c48c488f">XMLDIFF_SIBLING</a> = 16, 
<a class="el" href="../../d8/d55/group__transapi.html#gga10d59d84527f735d2781dbbb629a4488a732f013a15b9125ea90d20f16d2f2d8e">XMLDIFF_REORDER</a> = 32
<br/>
 }</td></tr>
<tr class="memdesc:ga10d59d84527f735d2781dbbb629a4488"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enum specifying states of node in document.  <a href="../../d8/d55/group__transapi.html#ga10d59d84527f735d2781dbbb629a4488">More...</a><br/></td></tr>
<tr class="separator:ga10d59d84527f735d2781dbbb629a4488"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:gacd42f4efcc256fa4ecdaa021f82d6d1f"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d8/d55/group__transapi.html#gacd42f4efcc256fa4ecdaa021f82d6d1f">ncds_add_augment_transapi</a> (const char *model_path, const char *callbacks_path)</td></tr>
<tr class="memdesc:gacd42f4efcc256fa4ecdaa021f82d6d1f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Extend datastore(s) with an augment model and its transAPI callbacks.  <a href="#gacd42f4efcc256fa4ecdaa021f82d6d1f">More...</a><br/></td></tr>
<tr class="separator:gacd42f4efcc256fa4ecdaa021f82d6d1f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga7f6f5af711045d8598f283ec09b9167a"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d8/d55/group__transapi.html#ga7f6f5af711045d8598f283ec09b9167a">ncds_add_augment_transapi_static</a> (const char *model_path, const struct <a class="el" href="../../d9/dc0/structtransapi.html">transapi</a> *<a class="el" href="../../d9/dc0/structtransapi.html">transapi</a>)</td></tr>
<tr class="memdesc:ga7f6f5af711045d8598f283ec09b9167a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Extend datastore(s) with an augment model and its transAPI callbacks.  <a href="#ga7f6f5af711045d8598f283ec09b9167a">More...</a><br/></td></tr>
<tr class="separator:ga7f6f5af711045d8598f283ec09b9167a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga80e69b4cada8c35e5e358287e8af3d85"><td class="memItemLeft" align="right" valign="top">struct ncds_ds *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d8/d55/group__transapi.html#ga80e69b4cada8c35e5e358287e8af3d85">ncds_new_transapi</a> (<a class="el" href="../../db/d67/group__store.html#gab0f0cbd5268577ec36fc76cf89c72a8f">NCDS_TYPE</a> type, const char *model_path, const char *callbacks_path)</td></tr>
<tr class="memdesc:ga80e69b4cada8c35e5e358287e8af3d85"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create new datastore structure with transaction API support.  <a href="#ga80e69b4cada8c35e5e358287e8af3d85">More...</a><br/></td></tr>
<tr class="separator:ga80e69b4cada8c35e5e358287e8af3d85"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaaf4e4daa7fa8be965ded41eb006a6713"><td class="memItemLeft" align="right" valign="top">struct ncds_ds *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d8/d55/group__transapi.html#gaaf4e4daa7fa8be965ded41eb006a6713">ncds_new_transapi_static</a> (<a class="el" href="../../db/d67/group__store.html#gab0f0cbd5268577ec36fc76cf89c72a8f">NCDS_TYPE</a> type, const char *model_path, const struct <a class="el" href="../../d9/dc0/structtransapi.html">transapi</a> *<a class="el" href="../../d9/dc0/structtransapi.html">transapi</a>)</td></tr>
<tr class="memdesc:gaaf4e4daa7fa8be965ded41eb006a6713"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create new datastore structure with transaction API support.  <a href="#gaaf4e4daa7fa8be965ded41eb006a6713">More...</a><br/></td></tr>
<tr class="separator:gaaf4e4daa7fa8be965ded41eb006a6713"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<p>libnetconf's implementation of transaction-based partial device reconfiguration. </p>
<h2 class="groupheader">Enumeration Type Documentation</h2>
<a class="anchor" id="ga10d59d84527f735d2781dbbb629a4488"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="../../d8/d55/group__transapi.html#ga10d59d84527f735d2781dbbb629a4488">XMLDIFF_OP</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Enum specifying states of node in document. </p>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><em><a class="anchor" id="gga10d59d84527f735d2781dbbb629a4488af2c3cac34cb7553ac93e8f3ad8acee3c"></a>XMLDIFF_ERR</em>&#160;</td><td class="fielddoc">
<p>Error while creating XML difftree. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga10d59d84527f735d2781dbbb629a4488a45a3557c464a0d85a333b68634df5561"></a>XMLDIFF_NONE</em>&#160;</td><td class="fielddoc">
<p>Last operation did not cause any change in configuration. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga10d59d84527f735d2781dbbb629a4488adc0f4fc8354a1e293db5efd4f8e6f0b1"></a>XMLDIFF_ADD</em>&#160;</td><td class="fielddoc">
<p>Element was added to configuration. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga10d59d84527f735d2781dbbb629a4488a149cdeec9d87bdbb700861f773759129"></a>XMLDIFF_REM</em>&#160;</td><td class="fielddoc">
<p>Element was removed from configuration. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga10d59d84527f735d2781dbbb629a4488a27c20d1fff6c4a35673bea8c6bbe23c4"></a>XMLDIFF_MOD</em>&#160;</td><td class="fielddoc">
<p>Element was modified. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga10d59d84527f735d2781dbbb629a4488a4038204cbce3cfa24153b304b95e99a6"></a>XMLDIFF_CHAIN</em>&#160;</td><td class="fielddoc">
<p>Some of children of element was modified/added/removed. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga10d59d84527f735d2781dbbb629a4488afed6f3e2b762ffe2cad87676c48c488f"></a>XMLDIFF_SIBLING</em>&#160;</td><td class="fielddoc">
<p>Some sibling nodes were added/removed/changed position. Only for LEAF and LEAF-LIST. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga10d59d84527f735d2781dbbb629a4488a732f013a15b9125ea90d20f16d2f2d8e"></a>XMLDIFF_REORDER</em>&#160;</td><td class="fielddoc">
<p>Some of the children nodes changed theirs position. None was added/removed. Only for LEAF and LEAF-LIST. </p>
</td></tr>
</table>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="gacd42f4efcc256fa4ecdaa021f82d6d1f"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int ncds_add_augment_transapi </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>model_path</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>callbacks_path</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Extend datastore(s) with an augment model and its transAPI callbacks. </p>
<p>The function must be called before <a class="el" href="../../db/d67/group__store.html#gab2a27448a52972db6807571590a5c6da" title="Consolidate all internal structures of created data stores and all data models. This function especia...">ncds_consolidate()</a>.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">model_path</td><td>Path of the file containing augment data model in the YIN format. libnetconf accepts data model augmenting multiple base data models linked with the datastores using <a class="el" href="../../d8/d55/group__transapi.html#ga80e69b4cada8c35e5e358287e8af3d85" title="Create new datastore structure with transaction API support. ">ncds_new_transapi()</a> function. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">callbacks_path</td><td>Path to shared library with callbacks and other functions for transaction API. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>EXIT_SUCCESS or EXIT_FAILURE </dd></dl>

</div>
</div>
<a class="anchor" id="ga7f6f5af711045d8598f283ec09b9167a"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int ncds_add_augment_transapi_static </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>model_path</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const struct <a class="el" href="../../d9/dc0/structtransapi.html">transapi</a> *&#160;</td>
          <td class="paramname"><em>transapi</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Extend datastore(s) with an augment model and its transAPI callbacks. </p>
<p>To make this function available, you have to include <a class="el" href="../../d5/d3e/libnetconf__xml_8h.html" title="libnetconf&#39;s main header for libxml2 variants of some functions. ">libnetconf_xml.h</a>.</p>
<p>The function must be called before <a class="el" href="../../db/d67/group__store.html#gab2a27448a52972db6807571590a5c6da" title="Consolidate all internal structures of created data stores and all data models. This function especia...">ncds_consolidate()</a>.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">model_path</td><td>Path of the file containing augment data model in the YIN format. libnetconf accepts data model augmenting multiple base data models linked with the datastores using <a class="el" href="../../d8/d55/group__transapi.html#ga80e69b4cada8c35e5e358287e8af3d85" title="Create new datastore structure with transaction API support. ">ncds_new_transapi()</a> function. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">transapi</td><td>Structure describing transAPI module. This way the module can be connected with the libnetconf library statically. The structure itself can be freed after the call, but the structure contains only pointers to other structures and variables that will be accessed directly from the subsequent functions using the returned datastore structure. These objects must not be freed during the existence of the returned datastore structure. However, these transAPI variables/structures are not freed by libnetconf. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>EXIT_SUCCESS or EXIT_FAILURE </dd></dl>

</div>
</div>
<a class="anchor" id="ga80e69b4cada8c35e5e358287e8af3d85"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct ncds_ds* ncds_new_transapi </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../db/d67/group__store.html#gab0f0cbd5268577ec36fc76cf89c72a8f">NCDS_TYPE</a>&#160;</td>
          <td class="paramname"><em>type</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>model_path</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>callbacks_path</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Create new datastore structure with transaction API support. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">type</td><td>Datastore implementation type for the new datastore structure. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">model_path</td><td>Base name of the configuration data model files. libnetconf expects model_path.yin as a data model, model_path.rng for grammar and data types validation, model_path.dsrl for default values validation and model_path.sch for semantic validation. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">callbacks_path</td><td>Path to shared library with callbacks and other functions for transaction API. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Prepared (not configured) datastore structure. To configure the structure, caller must use the parameter setters of the specific datastore implementation type. Then, the datastore can be initiated (<a class="el" href="../../db/d67/group__store.html#gaabb1ae2c497726ad826fc6478f97e8ff" title="Activate datastore structure for use. ">ncds_init()</a>) and used to access the configuration data. </dd></dl>

</div>
</div>
<a class="anchor" id="gaaf4e4daa7fa8be965ded41eb006a6713"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct ncds_ds* ncds_new_transapi_static </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../db/d67/group__store.html#gab0f0cbd5268577ec36fc76cf89c72a8f">NCDS_TYPE</a>&#160;</td>
          <td class="paramname"><em>type</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>model_path</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const struct <a class="el" href="../../d9/dc0/structtransapi.html">transapi</a> *&#160;</td>
          <td class="paramname"><em>transapi</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Create new datastore structure with transaction API support. </p>
<p>To make this function available, you have to include <a class="el" href="../../d5/d3e/libnetconf__xml_8h.html" title="libnetconf&#39;s main header for libxml2 variants of some functions. ">libnetconf_xml.h</a>.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">type</td><td>Datastore implementation type for the new datastore structure. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">model_path</td><td>Base name of the configuration data model files. libnetconf expects model_path.yin as a data model, model_path.rng for grammar and data types validation, model_path.dsrl for default values validation and model_path.sch for semantic validation. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">transapi</td><td>Structure describing transAPI module. This way the module can be connected with the libnetconf library statically. The structure itself can be freed after the call, but the structure contains only pointers to other structures and variables that will be accessed directly from the subsequent functions using the returned datastore structure. These objects must not be freed during the existence of the returned datastore structure. After <a class="el" href="../../db/d67/group__store.html#ga77b479cc1496b0c3883bb0f6bfe46754" title="Close the specified datastore and free all the resources. ">ncds_free()</a>, these transAPI variables/structures are not freed. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Prepared (not configured) datastore structure. To configure the structure, caller must use the parameter setters of the specific datastore implementation type. Then, the datastore can be initiated (<a class="el" href="../../db/d67/group__store.html#gaabb1ae2c497726ad826fc6478f97e8ff" title="Activate datastore structure for use. ">ncds_init()</a>) and used to access the configuration data. </dd></dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="footer">Generated on Fri Apr 15 2016 09:20:09 for libnetconf by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="../../doxygen.png" alt="doxygen"/></a> 1.8.6 </li>
  </ul>
</div>
</body>
</html>
